package kr.ragne.framework;

import kr.ragne.letsparis.GameState;
import android.app.Activity;
import android.content.res.Resources;
import android.graphics.Bitmap;
import android.graphics.BitmapFactory;

public class AppManager {
	private static AppManager s_instance;
	// Main GameView
	private GameView mGameView;
	// Main GameView의 Resources;
	private Resources mResources;
	
	public GameState gameState;
	public static boolean start = false;
	public static boolean isFlag = true;
	
	public static AppManager getInstance(){
		if(s_instance == null){
			s_instance = new AppManager();
		}
		
		return s_instance;
	}
	
	public Bitmap getBitmap(int r){
		return BitmapFactory.decodeResource(mResources, r);
	}

	public void setGameView(GameView mGameView) {
		this.mGameView = mGameView;
	}
	public void setResources(Resources mResources) {
		this.mResources = mResources;
	}
	public Resources getResources() {
		return mResources;
	}
	public GameView getGameView() {
		return mGameView;
	}
	
	public void getActivity(Activity activity) {
		activity.finish();
	}
	
}
